FROM openjdk:8
MAINTAINER panlin

# 将jar包添加到容器中，并命名为 springboot_docker.jar
ADD material-share-portal-1.0-SNAPSHOT.jar /material-share-portal-1.0-SNAPSHOT.jar
# 运行jar包
RUN bash -c 'touch material-share-portal-1.0-SNAPSHOT.jar'
ENTRYPOINT ["java", "-jar", "material-share-portal-1.0-SNAPSHOT.jar"]
 
# 设置时区
RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && echo 'Asia/Shanghai' >/etc/timezone
 
# SpringBoot项目配置的端口号为9999，需要将9999暴露出去 
EXPOSE 7073